import { ref, } from 'vue'
import { defineStore } from 'pinia'
import { getBannerAPI } from '@/apis/home'
export const useBannerList = defineStore('banner', () => {
    //!当前导航列表的逻辑

    //！state 导航列表数据
    const BannerList = ref([])
    //!action 导航列表方法
    const getBanner = async (data) => {
        let res = await getBannerAPI(data)
        if (res.code == 1) {
            BannerList.value = res.result
        }
    }

    return { BannerList, getBanner }
})
